//
//  ZDGiftViewController.m
//  1012GiftTips
//
//  Created by Apple on 15/10/15.
//  Copyright © 2015年 itcast. All rights reserved.
//

#import "ZDGiftCategoryViewController.h"
#import "ZDHelpSelectView.h"
//#import "ZDJumpViewController.h"
#import "Masonry.h"
#import "Global1.h"
#import "ZDMutiMenuView.h"

@interface ZDGiftCategoryViewController ()

@property (nonatomic, strong) ZDHelpSelectView *helpView;

@end

@implementation ZDGiftCategoryViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    //关闭滑动隐藏navigationBar
    self.navigationController.hidesBarsOnSwipe = NO;
    
    ZDHelpSelectView *helpView = [ZDHelpSelectView helpSelectView];
    
    helpView.helpLabel.text = @"选礼神器";
    
    UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapHelpSelectView:)];
    
    [helpView addGestureRecognizer:tapGesture];
    
    [self.view addSubview:helpView];
    
    
    [helpView mas_makeConstraints:^(MASConstraintMaker *make) {
        
        make.left.right.mas_equalTo(self.view);
        make.top.mas_equalTo(self.view).offset(64);
        make.height.mas_equalTo(30);
    }];
    
    
    ZDMutiMenuView *menuView = [ZDMutiMenuView mutiMenuView];
    
    [self.view addSubview:menuView];
    
    
    [menuView mas_makeConstraints:^(MASConstraintMaker *make) {
        
        make.top.mas_equalTo(helpView.mas_bottom);
        make.left.right.mas_equalTo(self.view);
        make.bottom.mas_equalTo(self.view).offset(-49);
    }];
    
}


- (void)viewDidLayoutSubviews
{
    self.helpView.frame = CGRectMake(0, 64, ZDScreenSize.width, 30);
}



#pragma mark - 点击手势回调方法
- (void)tapHelpSelectView:(UITapGestureRecognizer *)gesture
{
    //ZDJumpViewController *jumpVc = [[ZDJumpViewController alloc] init];
    
   // ZDHelpSelectView *view = (ZDHelpSelectView *)gesture.view;
    
    //jumpVc.title = view.helpLabel.text;
    
    //[self.navigationController pushViewController:jumpVc animated:YES];
}

@end
